package com.gordon.demo.controller;

import com.gordon.demo.user.User;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {

    @ApiOperation("简单测试接口")
    @GetMapping(value = "/test")
    public String test(@ApiParam("测试字符串") String test){
      return "测试jenkins咯";
    }

    @ApiOperation("测试登录方法1")
    @PostMapping(value = "/login")
    public String test1(@ApiParam("用户实例") User user){
        return "登录成功";
    }
}
